package org.example.day20240819;

public class Circle {
    Point circle_heart;
    double radius;

    public Circle(Point circle_heart, double radius) {
        this.circle_heart = circle_heart;
        this.radius = radius;
    }

    public boolean isPointInCircle(Point point){
        double distance = this.circle_heart.getDistance(point);
//        return distance <= this.radius;
        if(distance <= radius){
            return true;
        }else{
            return false;
        }
//        if(this.circle_heart.getDistance(point) <= this.radius){
//            return true;
//        }else{
//            return false;
//        }
    }

    @Override
    public String toString() {
        return "Circle{" +
                "circle_heart=" + circle_heart +
                ", radius=" + radius +
                '}';
    }
}
